package com.kaver.sso.dao.service.impl;

import com.kaver.sso.dao.po.SsoRole;
import com.kaver.sso.dao.mapper.SsoRoleMapper;
import com.kaver.sso.dao.service.SsoRoleDao;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 角色表 服务实现类
 * </p>
 *
 * @author roc
 * @since 2021-08-06
 */
@Service
public class SsoRoleDaoImpl extends ServiceImpl<SsoRoleMapper, SsoRole> implements SsoRoleDao {

	@Override
	public int queryGroupRoleCount(Long groupId) {
		SsoRole query = new SsoRole();
		query.setGroupId(groupId);
		QueryWrapper<SsoRole> queryWrapper = new QueryWrapper<SsoRole>(query);
		return this.count(queryWrapper);
	}

}
